﻿<UserControl x:Class="EFS.RC.Wallboard.Controls.Common.ImageLeftTextRectangle"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             BorderBrush="DarkGray" BorderThickness="2">
	<Grid Name="gridMain" VerticalAlignment="Stretch" HorizontalAlignment="Stretch">
		<Grid.ColumnDefinitions>
			<ColumnDefinition Width="30*"></ColumnDefinition>
			<ColumnDefinition Width="10"></ColumnDefinition>
			<ColumnDefinition Width="98*"></ColumnDefinition>
		</Grid.ColumnDefinitions>
		<Grid.RowDefinitions>
			<RowDefinition Height="34*"></RowDefinition>
		</Grid.RowDefinitions>

		<!-- The viewbox will stretch its content to fit the final size of the button -->
		<Viewbox Grid.Row="0" Grid.Column="0" Width="Auto" Margin="0" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
			<!-- The image and its contents are stretched to fill its parent -->
			<Image Height="24" Width="24" HorizontalAlignment="Center" Margin="5,5,5,5" Name="image" Stretch="Fill" VerticalAlignment="Center" Source="/EFS.RC.Wallboard;component/Resources/Icons/InUse/wallboard.ico" />
		</Viewbox>

		<!-- The viewbox will stretch its content to fit the final size of the button -->
		<Viewbox Grid.Row="0" Grid.Column="2" Margin="0" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Width="Auto">
			<!-- The textblock and its contents are stretched to fill its parent -->
			<TextBlock MinWidth="98" MinHeight="20" Width="Auto"  HorizontalAlignment="Center" VerticalAlignment="Center" Name="textBlock" Text="N/A" FontWeight="Normal" Foreground="Black" Margin="0,1,0,0" TextAlignment="Left" />
		</Viewbox>

		<Grid.Background>
			<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
				<GradientStop Color="White" Offset="1" />
				<GradientStop Color="#00ADD8E6" Offset="0" />
			</LinearGradientBrush>
		</Grid.Background>
	</Grid>
</UserControl>